import request from '@/utils/request'

export function updateAgent(data) {
  return request({
    url: '/agent/update',
    method: 'put',
    data: data
  })
}
export function deleteAgent(data) {
  return request({
    url: '/agent/delete',
    method: 'delete',
    data: data
  })
}
export function countAgent() {
  return request({
    url: '/agent/count',
    method: 'get',
  })
}
export function getAllAgent(data) {
  return request({
    url: '/agent/all',
    method: 'post',
    data: data
  })
}
export function getAllAgentDesc(data) {
  return request({
    url: '/agent/allDesc',
    method: 'post',
    data: data
  })
}
export function deleteAgentPo(data) {
  return request({
    url: '/agent/deletePo',
    method: 'delete',
    data: data
  })
}
export function deleteAgentPoMulti(data) {
  return request({
    url: '/agent/deletePoMulti',
    method: 'delete',
    data: data
  })
}
export function searchAgent(aName) {
  return request({
    url: '/agent/search/'+aName,
    method: 'get'
  })
}
export function updateAgentPo(data) {
  return request({
    url: '/agent/updatePo',
    method: 'put',
    data: data
  })
}
export function insertAgentPo(data) {
  return request({
    url: '/agent/insert',
    method: 'post',
    data: data
  })
}

